package kr.hs.kumoh.woohoo.view.activity;

import kr.hs.kumoh.woohoo.R;
import kr.hs.kumoh.woohoo.view.fragment.MenuListFragment;
import kr.hs.kumoh.woohoo.view.fragment.PopupFragment;
import android.os.Bundle;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentTransaction;

import com.actionbarsherlock.app.SherlockFragmentActivity;
import com.jeremyfeinstein.slidingmenu.lib.SlidingMenu;

public class MainActivity extends SherlockFragmentActivity {
	
	FragmentManager fragmentManager = getSupportFragmentManager();
	FragmentTransaction fragmentTransaction = fragmentManager.beginTransaction();
	
	MenuListFragment mlf = new MenuListFragment();
	PopupFragment pop = new PopupFragment();
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		getSupportActionBar();
		setContentView(R.layout.activity_main);
		
		pop.show(getSupportFragmentManager(), "POPUPTAG");
		
		SlidingMenu menu = new SlidingMenu(this);
		menu.setMode(SlidingMenu.LEFT);
	    menu.setTouchModeAbove(SlidingMenu.TOUCHMODE_FULLSCREEN);
	    menu.setShadowWidthRes(R.dimen.shadow_width);
	    menu.setBehindOffsetRes(R.dimen.slidingmenu_offset);
	    menu.setFadeDegree(0.35f);
	    menu.attachToActivity(this, SlidingMenu.SLIDING_WINDOW);
	    menu.setMenu(R.layout.slide_menu);
	    
        fragmentTransaction.show(mlf);
        fragmentTransaction.commit();
        
       
	}
	   
}
